perm filename QZ.MF[MF,DEK] blob sn#776961 filedate 1984-11-26 generic text, type C, neo UTF8
COMMENT āŠ—   VALID 00002 PAGES
C REC  PAGE   DESCRIPTION
C00001 00001
C00002 00002	% files rec'd from KTH Stockholm
C00008 ENDMK
CāŠ—;
% files rec'd from KTH Stockholm
% "ini.mf"
numeric elmerproof;
elmerproof=17;

def unknown = not known enddef;
def viewit = openit; showit; enddef;
def clearit = clearxy; viewit; enddef;
def beginchar(expr c_code,c_wd,c_ht,c_dp,c_ic,off_dw) =
 charcode:=c_code;
 charwd:=c_wd*designsize;
 charht:=c_ht*designsize;
 chardp:=c_dp*designsize;
 charic:=c_ic*designsize;
 chardw:=charwd*pt*off_dw;
 clearxy; currentpicture:=nulledges;
 begingroup
enddef;
def endchar = endgroup; if displaying>0: viewit fi; shipit;
enddef;
def beginfont(expr size, sch) =
 designsize:=size; %%codingscheme sch; fontsetup;
mode_setup; numeric un,ds;
 ds=un=designsize*pt;
 numeric slant, interword_space,interword_stretch,interword_shrink,
  x_height,quad_width,extra_space;
 numeric h_heigth,d_depth;
enddef;
def set_slant expr s =
 slant=s*pt;
 fontdimen 1:s;
enddef;
def set_interword_space expr s =
 interword_space=s*pt;
 fontdimen 2:s;
enddef;
def set_interword_stretch expr s =
 interword_stringch=s*pt;
 fontdimen 3:s;
enddef;
def set_interword_shrink expr s =
 interword_shrink=s*pt;
 fontdimen 4:s;
enddef;
def set_x_height expr s =
 x_height=s*pt;
 fontdimen 5:s;
enddef;
def set_quad_width expr s=
 quad_width=s*pt;
 fontdimen 6:s;
enddef;
def set_extra_space expr s =
 extra_space=s*pt;
 fontdimen 7:s;
enddef;
def set_h_height expr s =
 h_height=s*pt;
enddef;
def set_d_depth expr s =
 d_depth=s*pt;
enddef;
vardef circle(expr mid,rv) =
 save ett,tva,tre;
 pair ett,tva,tre;
 ett=mid+rv*(up);
 tva=mid+rv*(up rotated 120);
 tre=mid+rv*(up rotated-120);
 draw ett..tva..tre..cycle;
enddef;

%"qz10.mf":
mode:=canon;
beginfont(10,"UNSPECIFIED");
displaying:=1;
tracingstats:=2;
numeric qz_size;
qz_size=10;
set_slant 0;
set_interword_space (qz_size);
set_interword_stretch (3qz_size/20);
set_interword_shrink (2qz_size/20);
set_x_height (1/2qz_size);
set_quad_width (4qz_size);
set_h_height (qz_size);
set_d_depth 0;
vardef qz_ch(expr s) =
 save fk;
 numeric fk;
 fk=2**(s/2);
 save wd,th;
 numeric wd,ht;
 wd=fk*1.1qz_size/(10);
 ht=fk*(qz_size)/(10);
 save D,e;
 numeric D,e;
 D=5e=fk*qz_size*pt;
 def set_points =
  x0=y0=2.5e;
  x1=x4;
  x2=x3;
  y1=y2;
  y3=y4;
  x2-x1=y4-y1=D/(sqrt 2);
  x2-x0=x0-x1;
  y4-y0=y0-y1;
  z8=0.2[z4,z2];
  z6=0.2[z2,z4];
  save a,b,c,d;
  numeric a,b,c,d;
  z5=a[(x1+1e,y1),z3]=b[z6,(x6-1e,y6)];
  z7=c[z1,(x3-1e,y3)]=d[z8,(x8+1e,y8)];
  z9=-0.2[z2,z4];
  x10=x0;
  y10=y9;
 enddef;
 def markpoints =
  set_points;
  for i:=0 step 1 until 10: draw z[i]; endfor;
 enddef;
 def straight = tension 1000 enddef;
 def set_qz =
  set_points;
  path qz;
  qz=(z10{left}..z1{left+up}..z4{up+right}..z3{down+right}..
   z2{down+left}..straight..z6..straight..z5..straight..z3..straight..z4
   ..straight..z8..straight..z7..straight..z1..straight..
   z2..straight..z9..straight..cycle);
  path qz;
  qz=((z2{up+right}..z3{up+left}..z4{down+left}..z1{down+right}..z10{right})..%
   (z10..z9)..(z9..z2)..(z2..z1)..(z1..z7)..(z7..z8)..(z8..z4)..(z4..z3)..%
   (z3..z5)..(z5..z6)..(z6..z2)..cycle);
 enddef;
 beginchar((64+s),wd,ht,0,0,0);
  set_qz; fill qz;
 endchar;
enddef;
for j:=0 step 1 until 7: message ("["&decimal j&"]"); qz_ch(j); endfor;
end